﻿
using CSharpLibs.Annotations;

namespace System
{
	[Builtin]
	public interface ISignIntegralValue
	{
	}

	[Builtin]
	public interface IUSignIntegralValue
	{
	}

	[Builtin]
	public static class PrimitiveHelper
	{
		public static int DoCompareOpIntegral(long l1, long l2)
		{
			if(l1 < l2)
				return -1;
			else if(l1 == l2)
				return 0;
			else
				return 1;
		}

		public static int DoCompareOpIntegral(ulong l1, ulong l2)
		{
			if(l1 < l2)
				return -1;
			else if(l1 == l2)
				return 0;
			else
				return 1;
		}

		[BuiltinMethod, BuiltinSemantics("parse_as_integral")]
		public static long ParseIntegral(string sv)
		{ return -1; }

		[BuiltinMethod, BuiltinSemantics("format_integral_as_string")]
		public static string IntegralToString(long iv)
		{ return null; }

		[BuiltinMethod, BuiltinSemantics("parse_as_usignintegral")]
		public static ulong ParseUSignIntegral(string sv)
		{ return 0; }

		[BuiltinMethod, BuiltinSemantics("format_usignintegral_as_string")]
		public static string USignIntegralToString(ulong iv)
		{ return null; }

		[BuiltinMethod, BuiltinSemantics("parse_as_floatingpoint")]
		public static double ParseFloatingPoint(string sv)
		{ return -1; }

		[BuiltinMethod, BuiltinSemantics("format_floatingpoint_as_string")]
		public static string FloatPointToString(double d)
		{ return null; }
	}
}
